import React from 'react';
import { Result, Button } from 'antd';
import { useRouter } from 'next/router';
import { HomeOutlined } from '@ant-design/icons';

const NotFoundPage: React.FC = () => {
  const router = useRouter();

  return (
    <div style={{
      minHeight: '100vh',
      display: 'flex',
      alignItems: 'center',
      justifyContent: 'center',
      background: '#f0f2f5'
    }}>
      <Result
        status="404"
        title="404"
        subTitle="抱歉，您访问的页面不存在。"
        extra={
          <Button 
            type="primary" 
            icon={<HomeOutlined />}
            onClick={() => router.push('/')}
          >
            返回首页
          </Button>
        }
      />
    </div>
  );
};

export default NotFoundPage;